package com.tao.design.facade;

/**
 * @projectName: DesignMode
 * @package: com.tao.design.facade
 * @className: Facade
 * @author: TT_Hugo
 * @description: TODO
 * @date: 2022/12/26 22:08
 * @version: 1.0
 */
public class Facade {
    ServiceA sa;
    ServiceB sb;
    ServiceC sc;

    public Facade() {
        sa = new ServiceAImpl();
        sb = new ServiceBImpl();
        sc = new ServiceCImpl();
    }

    public void methodA() {
        sa.methodA();
        sb.methodB();
    }

    public void methodB() {
        sb.methodB();
        sc.methodC();
    }

    public void methodC() {
        sc.methodC();
        sa.methodA();
    }
}
